package org.example.frw.api.base.request;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.example.frw.api.base.intf.Pageable;

@Setter
@Getter
@NoArgsConstructor
@AllArgsConstructor
public class PageQueryRequest implements Pageable {
  private Integer current;
  private Integer pageSize;

  @Override
  public int current() {
    return current == null? 1: current;
  }

  @Override
  public int pageSize() {
    return pageSize == null?10:pageSize;
  }
}